#include "aboutdialog.h"
#include "ui_aboutdialog.h"

#include <QDesktopServices>

AboutDialog::AboutDialog(QWidget *parent) :
    QDialog(parent),
    ui(new Ui::AboutDialog)
{
    ui->setupUi(this);
    connect(ui->aboutText, SIGNAL(anchorClicked(QUrl)), this, SLOT(slotOpenLink(QUrl)));
}

AboutDialog::~AboutDialog()
{
    delete ui;
}

void AboutDialog::setAbout(QString about)
{
    ui->aboutText->setText(about);
}

void AboutDialog::setAbout(QUrl abouturl)
{
    ui->aboutText->setSource(abouturl);
}

void AboutDialog::slotOpenLink(QUrl uri)
{
        QDesktopServices::openUrl(uri);
}
